//
//  ListCollectionReusableView.m
//  Cat
//
//  Created by lushitong on 2019/1/15.
//  Copyright © 2019年 lushitong. All rights reserved.
//

#import "ListCollectionReusableView.h"
#import "GHDropMenuModel.h"
#import "GHDropMenu.h"

@interface ListCollectionReusableView()<GHDropMenuDelegate>

@end

@implementation ListCollectionReusableView

-(instancetype)initWithFrame:(CGRect)frame {
	self = [super initWithFrame:frame];
	if (self) {
		self.userInteractionEnabled = YES;
		/** 配置筛选菜单模型 */
		GHDropMenuModel *configuration = [[GHDropMenuModel alloc]init];
		/** 配置筛选菜单是否记录用户选中 默认NO */
		configuration.recordSeleted = NO;
		/** 设置数据源 */
		configuration.titles = [configuration creaDropMenuData];
		/** 创建dropMenu 配置模型 && frame */
		
		GHDropMenu *dropMenu = [GHDropMenu creatDropMenuWithConfiguration:configuration frame:CGRectMake(0, 0.0,ScreenWidth, kQKFitModuleDecimal(34.0)) dropMenuTitleBlock:^(GHDropMenuModel * _Nonnull dropMenuModel) {
			
		} dropMenuTagArrayBlock:^(NSArray * _Nonnull tagArray) {
			
		}];
		
		dropMenu.titleSeletedColor = COLOR_WITH_HEX(0x4C4947);
		dropMenu.titleNormalColor = COLOR_WITH_HEX(0x756D68);
		dropMenu.optionFont = [UIFont systemFontOfSize:kQKFitFont(12)];
		dropMenu.optionSeletedColor = COLOR_WITH_HEX(0x4C4947);
		dropMenu.optionNormalColor = COLOR_WITH_HEX(0x756D68);
		dropMenu.titleNormalImageName = @"menu_arrow_up";
		dropMenu.titleSeletedImageName = @"menu_arrow_down";
		dropMenu.delegate = self;
		dropMenu.durationTime = 0.25;
		[self addSubview:dropMenu];
	}
	return self;
}

#pragma mark----- lazy init -----

#pragma mark - 代理回调

- (void)dropMenu:(GHDropMenu *)dropMenu dropMenuTitleModel:(GHDropMenuModel *)dropMenuTitleModel {
	
}


@end
